<?php
namespace app\admin\controller;
use \think\Session;
use \think\Controller;

class Base extends Controller
{
    public function _initialize()
    {
    $userId = $this->is_login();
    if($userId==0)
    {
  //  $this->redirect('user/loginPortal');
    }
    }
    public function is_login()
    {
     $userId = Session::get('userId');
     if(empty($userId)) $userId=0;
     return $userId;
    }




}
